﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Com.Charence.PassManager.BusinessComponents;
using Com.Charence.PassManager.Common;
using Com.Charence.PassManager.UI.Web.Common;
using Com.Charence.PassManager.UI.Web.Models.Dashboard;

namespace Com.Charence.PassManager.UI.Web.Controllers
{
    public class DashboardController : BaseController
    {
        //
        // GET: /Dashboard/

        public ActionResult Index()
        {
            var bc = new DashboardBC();
            var accountSummary = bc.GetLast10AccountSummary(AppContext.Current.LoginUserID);
            var viewModel = AutoMapper.Mapper.Map<List<AccountSummaryModel>>(accountSummary);
            return View(viewModel);
        }

    }
}
